// 导入axios实例
import http from './request';


// http.get()   可以返回promise实例

// 1：搜索
export const Search = (data={})=> {
    return http.get('search/book/data.json',{params: data})
}

// 2：推荐
export const Personalized = (data={})=> {
    return http.get('source/v2/searchBook.json?catId=7&wordCount=0&pay=0&bookStatus=0&sort=1',{params: data})
}

// 3.分类
export const Sortdatas = (data={})=> {
    return http.get('simpleCategroy.json',{params: data})
}

// // 4.章节列表
// export const lists = (data={})=> {
//     return http.get('book/catalog.json',{params: data})
// }

// 4.详情
export const Details = (data = {}) => {
    return http.get('book/getsub.json', { params: data });
}

// 5.章节列表
export const Chapters = (data = {}) => {
    return http.get('reader/book/info.json', { params: data });
}
    // // 章节内容
    // bookcontent :'reader/book/content.json',

// 5.章节内容
export const BookContent = (data = {}) => {
    return http.get('reader/book/content.json', { params: data });
}